﻿@{
    Layout = null;

    var tempMsg = TempData["LoginMessage"];

}
<!DOCTYPE html>

<html>

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <title>登录</title>

    <link href="~/Content/layui/css/layui.css" rel="stylesheet" media="all" />
    <link rel="stylesheet" href="~/Content/css/login.css" />
</head>

<body class="beg-login-bg">
    <div class="beg-login-box">
        <header>
            <h1>后台登录</h1>
        </header>
        <div class="beg-login-main">
            <form action="/login/login" class="layui-form" method="post">
                @Html.AntiForgeryToken()
                <div class="layui-form-item">
                    <label class="beg-login-icon">
                        <i class="layui-icon">&#xe612;</i>
                    </label>
                    <input type="text" name="userName" lay-verify="required" autocomplete="off" placeholder="这里输入登录名" class="layui-input" />
                </div>
                <div class="layui-form-item">
                    <label class="beg-login-icon">
                        <i class="layui-icon">&#xe642;</i>
                    </label>
                    <input type="password" name="password" lay-verify="required" autocomplete="off" placeholder="这里输入密码" class="layui-input" />
                </div>
                <div class="layui-form-item">

                    <div class="beg-pull-right">
                        <button class="layui-btn layui-btn-primary" lay-submit lay-filter="login">
                            登录
                        </button>
                    </div>
                    <div class="beg-clear"></div>
                </div>
            </form>
        </div>
    </div>
    <script type="text/javascript" src="~/Content/layui/layui.js"></script>
    <script>
        layui.use(['layer', 'form'], function () {
            var layer = layui.layer,
                $ = layui.jquery,
                form = layui.form();

            @if (tempMsg!=null)
            {
                <text>
                layer.msg('@Html.Raw(tempMsg)');
            </text>
            }

            form.on('submit(login)', function (data) {
            });
        });
    </script>
</body>

</html>